home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1991 …esperately Seeking Seven / Desperately Seeking Seven.2mg / Dev.CD.8 / Essentials / Tools / Technical.Notes / Misc / TN.MISC.003 < prev    next >
Encoding:
Text File  |  1988-11-15  |  2.5 KB  |  56 lines  |  [04] ASCII Text (0x0000)

  1. Apple II
  2. Technical Notes
  3. _____________________________________________________________________________
  4.                                                   Developer Technical Support
  5.  
  6.  
  7. Apple II Miscellaneous
  8. #3:    Super Serial Card Firmware Bug
  9.  
  10. Revised by:    Matt Deatherage                                  November 1988
  11. Written by:    Cameron Birse                                    November 1985
  12.  
  13. This Technical Note documents two bugs in the Super Serial Card firmware.
  14. _____________________________________________________________________________
  15.  
  16. The Super Serial Card (SSC) firmware does not access location $CFFF to clear 
  17. the $C800 space before jumping into its bank-switched ROM in that area.
  18.  
  19. By omitting this access, the Super Serial Card can cause a slot data bus 
  20. conflict when a ROM of equal or greater strength on another card "owns" the 
  21. $C800 space when the Super Serial Card wants to use it.  For example, the 
  22. UniDisk 3.5 controller card uses the same 74LS245 octal bus driver as the 
  23. Super Serial Card.  If you are using the UniDisk 3.5 card and switch to the 
  24. Super Serial Card firmware, there will be a bus conflict .  The SSC is trying 
  25. to switch in its own $C800 space while the UniDisk 3.5 card is trying to keep 
  26. the $C800 space, since no one cleared it by accessing $CFFF.  Since both have 
  27. the same capability to drive the bus, neither wins the battle.
  28.  
  29. An easy solution to this problem is to reference $CFFF before calling any of 
  30. the Pascal entry points on the Super Serial Card.  For example:
  31.  
  32. NEWSLOT    STA    $CFFF         ;reset the slot ROM space
  33.            LDA    Char          ;Char = character to output
  34.            LDX    #$Cn          ;n = slot number
  35.            LDY    #$n0
  36.            STX    MSLOT         ;MSLOT = $7F8, always set it up
  37.            JSR    PWRITE        ;now call the Pascal routine of your choice
  38.  
  39. This bug is in the Pascal entry points; the BASIC entry point does not have 
  40. this problem as there is a STA $CFFF instruction at $Cn1B.
  41.  
  42. This example code stores the slot number (in the form $Cn) in MSLOT, a screen 
  43. hole used to tell the system which peripheral card had control when an 
  44. interrupt occurred.  The Super Serial Card firmware does set up MSLOT, but 
  45. does not do so until long after it has enabled its $C800 space.  If an IRQ 
  46. comes through the system between the call to the card and when the card stores 
  47. MSLOT, the system will crash.
  48.  
  49. Both bugs can be avoided by using the sample code to call entry points on the 
  50. Super Serial Card.
  51.  
  52.  
  53. Further Reference
  54. o    Apple IIe Technical Reference Manual
  55.  
  56.